package org.jeecg.modules.system.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;
import org.jeecg.modules.system.entity.SysAirProduct;

import java.math.BigDecimal;
import java.util.List;

/**
 * @Description: 分类字典
 * @Author: jeecg-boot
 * @Date: 2019-05-29
 * @Version: V1.0
 */
public interface SysAirProductMapper extends BaseMapper<SysAirProduct> {

    @Select("select * from sys_air_product where mow_min<=#{s} and mow_max>=#{s}\n" +
            "UNION\n" +
            "select * from sys_air_product where mow_min>=#{s} and mow_max is null\n" +
            "UNION\n" +
            "select * from sys_air_product where mow_max<=#{s} and mow_min is null")
    List<SysAirProduct> matchProduct(BigDecimal w);
}
